﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Mvc;
using Zoomtel.Entity;
using Zoomtel.Persist.BIZ.Models;
using Zoomtel.Service.BIZ;
using Zoomtel.Web.Controllers;

namespace Zoomtel.Web.Areas.Pub.Controllers
{
    [Description("分销收益接口")]
    public class ProfitController : PubModuleController
    {
        ProfitService _profitService;
        ILoginInfo loginInfo;
        public ProfitController(ProfitService profitService,ILoginInfo _loginInfo)
        {
            _profitService = profitService;
            loginInfo = _loginInfo;

        }

        [HttpPost]
        [Description("查询")]
        public Task<IResultModel> QueryCalcResult(ProfitQueryMode model)
        {
            model.AgentId = loginInfo.Uid;
            return _profitService.QueryCalcResult(model);
        }

    }
}